<h2 class="h2-title">Danh sách tài khoản !!!</h2>

<p><a href="<?=base_url()?>backend/user/createuser" class="bnt"style="margin-bottom: 15px;">Tạo tài khoản</a></p>

<div class="clear"></div>
<?php if($this->native_session->flashdata('msg')):?>
    <ul class="notification succ">
        <li class="notifi_img"><img src="<?=base_url()?>assets/backend/css/images/icons/tick_circle.png"/></li>

        <li class="msg"><?=$this->native_session->flashdata('msg')?></li>

        <li class="close"><img src="<?=base_url()?>assets/backend/css/images/icons/cross_grey_small.png"/></li>

    </ul><!--End of .notification -->
<?php endif?>

<table class="pretty">
                    <thead>
                        <tr>
                            <th>Mã tài khoản</th>
                            <th>Tên đăng nhập</th>
                            <th>Tên đầy đủ</th>
                            <th>Email</th>
                            <th>Sửa</th>
                            <th>Xoá</th>
                        </tr>
                    </thead>

                    <tbody>
                        <?php if(isset($msg)):?>
                            <td colspan="6"><?= $msg ?></td>
                        <?php else:?>
                            <?php foreach($users as $user):?>
                                <tr>
                                <td><?=$user->admin_id?></td>
                                <td><?=$user->admin_username?></td>
                                <td><?=$user->admin_fullname?></td>
                                <td><?=$user->admin_email?></td>
                                <td>
                                    <a href="<?=base_url()?>backend/user/edituser/<?=$user->admin_id?>" class="edit">
                                        <img src="<?=base_url()?>assets/backend/css/images/edit.png"/>
                                    </a>
                                </td>
                                <td>
                                    <a href="<?=base_url()?>backend/user/deluser/<?=$user->admin_id?>" class="delete">
                                        <img src="<?=base_url()?>assets/backend/css/images/delete.png"/>
                                    </a>
                                </td>
                                </tr>
                            <?php endforeach;?>
                        <?php endif;?>
                    </tbody>
                </table>